package week04.graph01;

import java.util.List;

/**
 * Created by zhangxiaokun on 2018/2/28.
 */
public abstract class Graphic {
     public abstract void draw();
     public abstract void add(Graphic graphic);
     public abstract boolean remove(Graphic graphic);
     public abstract Graphic getChild(int index);
    public abstract List<Graphic> getAllChild();

     public boolean isPicture(){
         if (this instanceof Picture) {
             return true;
         }
         return false;
     }
}
